package com.ts.content.controller;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ts.content.entity.DiscussEntity;
import com.ts.content.service.DiscussService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/discuss")
public class DiscussController {

    @Autowired
    private DiscussService discussService;

    @PostMapping("/page")
    public Page<DiscussEntity> page(@RequestBody Page<DiscussEntity> page){
        return discussService.page(page);
    }
}
